Optimal. Leaf size=140 \[ -\frac {8 a^3 (i A+B)}{f \sqrt {c-i c \tan (e+f x)}}-\frac {8 a^3 (i A+2 B) \sqrt {c-i c \tan (e+f x)}}{c f}+\frac {2 a^3 (i A+5 B) (c-i c \tan (e+f x))^{3/2}}{3 c^2 f}-\frac {2 a^3 B (c-i c \tan (e+f x))^{5/2}}{5 c^3 f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.13, antiderivative size = 140, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 2, integrand size = 43, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.047, Rules used = {3669, 78}
\begin {gather*} \frac {2 a^3 (5 B+i A) (c-i c \tan (e+f x))^{3/2}}{3 c^2 f}-\frac {8 a^3 (2 B+i A) \sqrt {c-i c \tan (e+f x)}}{c f}-\frac {8 a^3 (B+i A)}{f \sqrt {c-i c \tan (e+f x)}}-\frac {2 a^3 B (c-i c \tan (e+f x))^{5/2}}{5 c^3 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 78
Rule 3669
Rubi steps
\begin {align*} \int \frac {(a+i a \tan (e+f x))^3 (A+B \tan (e+f x))}{\sqrt {c-i c \tan (e+f x)}} \, dx &=\frac {(a c) \text {Subst}\left (\int \frac {(a+i a x)^2 (A+B x)}{(c-i c x)^{3/2}} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {(a c) \text {Subst}\left (\int \left (\frac {4 a^2 (A-i B)}{(c-i c x)^{3/2}}-\frac {4 a^2 (A-2 i B)}{c \sqrt {c-i c x}}+\frac {a^2 (A-5 i B) \sqrt {c-i c x}}{c^2}+\frac {i a^2 B (c-i c x)^{3/2}}{c^3}\right ) \, dx,x,\tan (e+f x)\right )}{f}\\ &=-\frac {8 a^3 (i A+B)}{f \sqrt {c-i c \tan (e+f x)}}-\frac {8 a^3 (i A+2 B) \sqrt {c-i c \tan (e+f x)}}{c f}+\frac {2 a^3 (i A+5 B) (c-i c \tan (e+f x))^{3/2}}{3 c^2 f}-\frac {2 a^3 B (c-i c \tan (e+f x))^{5/2}}{5 c^3 f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 2.47, size = 152, normalized size = 1.09 \begin {gather*} -\frac {2 a^3 (\cos (e+4 f x)+i \sin (e+4 f x)) (A+B \tan (e+f x)) \sqrt {c-i c \tan (e+f x)} (60 i A+87 B+(25 A-38 i B) \tan (e+f x)+\cos (2 (e+f x)) (55 i A+71 B+(25 A-41 i B) \tan (e+f x)))}{15 c f (\cos (f x)+i \sin (f x))^3 (A \cos (e+f x)+B \sin (e+f x))} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.25, size = 135, normalized size = 0.96
method | result | size |
derivativedivides | \(\frac {2 i a^{3} \left (\frac {i B \left (c -i c \tan \left (f x +e \right )\right )^{\frac {5}{2}}}{5}-\frac {5 i B c \left (c -i c \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3}+\frac {A c \left (c -i c \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3}+8 i B \,c^{2} \sqrt {c -i c \tan \left (f x +e \right )}-4 A \,c^{2} \sqrt {c -i c \tan \left (f x +e \right )}-\frac {4 c^{3} \left (-i B +A \right )}{\sqrt {c -i c \tan \left (f x +e \right )}}\right )}{f \,c^{3}}\) | \(135\) |
default | \(\frac {2 i a^{3} \left (\frac {i B \left (c -i c \tan \left (f x +e \right )\right )^{\frac {5}{2}}}{5}-\frac {5 i B c \left (c -i c \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3}+\frac {A c \left (c -i c \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3}+8 i B \,c^{2} \sqrt {c -i c \tan \left (f x +e \right )}-4 A \,c^{2} \sqrt {c -i c \tan \left (f x +e \right )}-\frac {4 c^{3} \left (-i B +A \right )}{\sqrt {c -i c \tan \left (f x +e \right )}}\right )}{f \,c^{3}}\) | \(135\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.30, size = 112, normalized size = 0.80 \begin {gather*} -\frac {2 i \, {\left (\frac {60 \, {\left (A - i \, B\right )} a^{3} c}{\sqrt {-i \, c \tan \left (f x + e\right ) + c}} - \frac {3 i \, {\left (-i \, c \tan \left (f x + e\right ) + c\right )}^{\frac {5}{2}} B a^{3} + 5 \, {\left (-i \, c \tan \left (f x + e\right ) + c\right )}^{\frac {3}{2}} {\left (A - 5 i \, B\right )} a^{3} c - 60 \, \sqrt {-i \, c \tan \left (f x + e\right ) + c} {\left (A - 2 i \, B\right )} a^{3} c^{2}}{c^{2}}\right )}}{15 \, c f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.99, size = 133, normalized size = 0.95 \begin {gather*} -\frac {4 \, \sqrt {2} {\left (15 \, {\left (i \, A + B\right )} a^{3} e^{\left (6 i \, f x + 6 i \, e\right )} + 15 \, {\left (5 i \, A + 7 \, B\right )} a^{3} e^{\left (4 i \, f x + 4 i \, e\right )} + 20 \, {\left (5 i \, A + 7 \, B\right )} a^{3} e^{\left (2 i \, f x + 2 i \, e\right )} + 8 \, {\left (5 i \, A + 7 \, B\right )} a^{3}\right )} \sqrt {\frac {c}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}}}{15 \, {\left (c f e^{\left (4 i \, f x + 4 i \, e\right )} + 2 \, c f e^{\left (2 i \, f x + 2 i \, e\right )} + c f\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - i a^{3} \left (\int \frac {i A}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\, dx + \int \left (- \frac {3 A \tan {\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\right )\, dx + \int \frac {A \tan ^{3}{\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\, dx + \int \left (- \frac {3 B \tan ^{2}{\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\right )\, dx + \int \frac {B \tan ^{4}{\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\, dx + \int \left (- \frac {3 i A \tan ^{2}{\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\right )\, dx + \int \frac {i B \tan {\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\, dx + \int \left (- \frac {3 i B \tan ^{3}{\left (e + f x \right )}}{\sqrt {- i c \tan {\left (e + f x \right )} + c}}\right )\, dx\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 12.43, size = 351, normalized size = 2.51 \begin {gather*} -\sqrt {c+\frac {c\,\left ({\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}\,1{}\mathrm {i}-\mathrm {i}\right )\,1{}\mathrm {i}}{{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1}}\,\left (\frac {a^3\,\left (A-B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{c\,f}+\frac {a^3\,{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}\,\left (A-B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{c\,f}\right )-\left (\frac {a^3\,\left (A-B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{c\,f}+\frac {a^3\,\left (A-B\,3{}\mathrm {i}\right )\,4{}\mathrm {i}}{c\,f}\right )\,\sqrt {c+\frac {c\,\left ({\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}\,1{}\mathrm {i}-\mathrm {i}\right )\,1{}\mathrm {i}}{{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1}}-\frac {\left (\frac {a^3\,\left (A-B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{5\,c\,f}-\frac {a^3\,\left (A+B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{5\,c\,f}\right )\,\sqrt {c+\frac {c\,\left ({\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}\,1{}\mathrm {i}-\mathrm {i}\right )\,1{}\mathrm {i}}{{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1}}}{{\left ({\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1\right )}^2}+\frac {\left (\frac {16\,B\,a^3}{3\,c\,f}+\frac {a^3\,\left (A-B\,1{}\mathrm {i}\right )\,4{}\mathrm {i}}{3\,c\,f}\right )\,\sqrt {c+\frac {c\,\left ({\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}\,1{}\mathrm {i}-\mathrm {i}\right )\,1{}\mathrm {i}}{{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1}}}{{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________